<!DOCTYPE html>
<html lang="en"  xmlns:th="http://www.thymeleaf.org"
      th:replace="public/body/layout">
<div class="page-head" th:fragment="pageHeder">
    <h2 class="page-head-title">资源信息管理</h2>
    <ol class="breadcrumb page-head-nav">
        <li class="active">资源信息管理</li>
    </ol>
</div>
<div th:fragment="content">
    <div class="row">
        <!--Responsive table-->
        <div class="col-sm-12">
            <div class="panel panel-default panel-table panel-border-color panel-border-color-primary">
                <div class="panel-heading">

                </div>
                <div class="panel-body">
                    <div class="table-responsive noSwipe">
                        <table class="table table-striped table-hover table-bordered table-condensed">
                            <thead>
                            <tr>
                                <th style="width:5%;">
                                    <div class="be-checkbox be-checkbox-sm">
                                        <input id="check1" type="checkbox">
                                        <label for="check1"></label>
                                    </div>
                                </th>
                                <th style="width:5%;">序号</th>
                                <th style="width:20%;">资源名称</th>
                                <th style="width:10%;">资源类型</th>
                                <th style="width:5%;">资源图标</th>
                                <th style="width:5%;">资源级别</th>
                                <th style="width:5%;">状态</th>
                                <th style="width:10%;">创建时间</th>
                                <th style="width:10%;">更新时间</th>
                                <th style="width:25%;">操作</th>
                            </tr>
                            </thead>
                            <tbody>
                            <tr th:if="${not #lists.isEmpty(resourceList)}" th:each="resource ,iterStat : ${resourceList.content}" th:class="${iterStat.odd}? 'online'">
                                <td>
                                    <div class="be-checkbox be-checkbox-sm">
                                        <input th:id="|check ${iterStat.count}|" type="checkbox">
                                        <label th:for="|check ${iterStat.count}|"></label>
                                    </div>
                                </td>
                                <td th:text="${iterStat.count}">序号</td>
                                <td class="cell-detail">
                                    <span th:text="${resource.resourceName}">Initial commit</span>
                                </td>
                                <td class="cell-detail">
                                    <span th:text="${resource.resourceType}">Initial commit</span>
                                </td>
                                <td class="cell-detail">
                                    <span th:text="${resource.resourceIcon}">Initial commit</span>
                                </td>
                                <td class="cell-detail">
                                    <span th:text="${resource.resourceLevel}">Initial commit</span>
                                </td>
                                <td class="cell-detail" th:switch="${resource.ifUse}">
                                    <a href="#" th:text="启用" th:case="1" class="btn btn-success be-booking-btn-price">启用</a>
                                    <a href="#" th:text="禁用" th:case="2" class="btn btn-danger be-booking-btn-price">启用</a>
                                    <a href="#" th:text="未知" th:case="*" class="btn btn-warning be-booking-btn-price">启用</a>
                                </td>

                                <td class="cell-detail">
                                    <span th:text="${#calendars.format(resource.createDate,'yyyy年MM月dd日')}">May 6, 2016</span>
                                    <span class="cell-detail-description" th:text="${#calendars.format(resource.createDate,'HH时mm分')}">8:30</span>
                                </td>
                                <td class="cell-detail">
                                    <span th:text="${#calendars.format(resource.updateDate,'yyyy年MM月dd日')}">May 6, 2016</span>
                                    <span class="cell-detail-description" th:text="${#calendars.format(resource.updateDate,'HH时mm分')}">8:30</span>
                                </td>
                                <td class="cell-detail xs-mt-10">
                                    <div class="btn-group btn-space">
                                        <button type="button" class="btn btn-color btn-social btn-facebook">
                                            <i class="icon mdi mdi-hospital"></i>
                                        </button>
                                        <button type="button" class="btn btn-default"  th:onclick="">新增</button>
                                    </div>
                                    <div class="btn-group btn-space">
                                        <button type="button" class="btn btn-color btn-social btn-facebook">
                                            <i class="icon mdi mdi-open-in-new"></i>
                                        </button>
                                        <button type="button" class="btn btn-default"  th:onclick="">详情</button>
                                    </div>
                                    <div class="btn-group btn-space">
                                        <button type="button" class="btn btn-color btn-social btn-twitter">
                                            <i class="icon mdi mdi-edit"></i>
                                        </button>
                                        <button type="button" class="btn btn-default" th:onclick="">编辑</button>
                                    </div>
                                    <div class="btn-group btn-space">
                                        <button type="button" class="btn btn-color btn-social btn-google-plus">
                                            <i class="icon mdi mdi-delete"></i>
                                        </button>
                                        <button type="button" class="btn btn-default"  data-toggle="modal" data-target="#md-footer-warning" th:onclick="">删除</button>
                                    </div>
                                </td>
                            </tr>
                            </tbody>
                        </table>
                    </div>
                </div>
            </div>


            <div id="md-footer-warning" tabindex="-1" role="dialog" class="modal fade">
                <div class="modal-dialog">
                    <div class="modal-content">
                        <div class="modal-header">
                            <button type="button" data-dismiss="modal" aria-hidden="true" class="close">
                                <span class="mdi mdi-close"></span>
                            </button>
                        </div>
                        <div class="modal-body">
                            <div class="text-center">
                                <div class="text-warning">
                                    <span class="modal-main-icon mdi mdi-alert-triangle"></span>
                                </div>
                                <h3>您确定要删除此资源吗？</h3>
                                <p>该资源将执行永久删除.</p>
                            </div>
                        </div>
                        <div class="modal-footer">
                            <button type="button" data-dismiss="modal" class="btn btn-default">取消</button>
                            <button type="button" data-dismiss="modal" class="btn btn-warning" th:onclick="remove([[${tts}]])">确定</button>
                        </div>
                    </div>
                </div>
            </div>

        </div>
    </div>
    <script th:src="@{/js/resource/resource.js}" type="text/javascript"></script>
</div>
</html>